<% form_for(@movie) do |f| %>
  <%= f.error_messages %>
  <% field_set_tag "Movie Details" do %>
    <ul>
      <li><%= f.label :title, "Movie Title:" %><%= f.text_field :title %></li>
      <li><%= f.label :rating, "Movie Rating:" %><%= f.select :rating, options_for_select(%w[G PG PG-13 R NC-17], @movie.rating) %></li>
      <li><%= f.label :released_on, "Release Date:" %><%= f.date_select :released_on %></li>
      <li><%= f.label :description, "Movie Description:" %><%= f.text_area :description %></li>
      <li><%= f.submit @movie.new_record? ? "Add Movie!" : "Update Movie!", :id => "submit" %></li> 
    </ul>
  <% end %>
<% end %>
